package main

import "fmt"

func main()  {
	//a:=[6]int{1,2,3,4,5,5}
	//b:=a[1:4]
	//a[2]=111
	//fmt.Println(a,b)
	//fmt.Println(&a,&b)

	p:=pr{2}
	fmt.Println(p)
	i := mergr(&p)
	fmt.Println(i.val)
	fmt.Println(p.val)

}

type pr struct {
	val int
}

func mergr(p *pr) *pr {
	p.val=22
	return p
}
